package com.zhijian.wharf.dao;

import com.zhijian.wharf.entity.po.Weather;
import com.zhijian.wharf.entity.vo.request.WeatherSearchVo;
import com.zhijian.wharf.entity.vo.response.WeatherVo;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface WeatherMapper {
    int deleteByPrimaryKey(Long id);

    int insert(Weather record);

    int insertSelective(Weather record);

    Weather selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(Weather record);

    int updateByPrimaryKey(Weather record);

    /**
     * 查询总数
     *
     * @param weatherSearchVo
     * @return
     */
    int count(WeatherSearchVo weatherSearchVo);

    /**
     * 查询列表
     *
     * @param weatherSearchVo
     * @return
     */
    List<WeatherVo> selectList(WeatherSearchVo weatherSearchVo);

    /**
     * 查询单个
     *
     * @param weatherSearchVo
     * @return
     */
    WeatherVo selectOne(WeatherSearchVo weatherSearchVo);

    /**
     * 根据ID查询vo
     *
     * @param id
     * @return
     */
    WeatherVo selectVoById(Long id);

    /**
     * 批量删除
     *
     * @param idList
     * @return
     */
    void deleteByIdList(@Param("idList") List<Long> idList);

    /**
     * 动态删除
     *
     * @param weatherSearchVo
     * @return
     */
    void deleteByCondition(WeatherSearchVo weatherSearchVo);

    /**
     * 批量新增
     *
     * @param entities
     * @return
     */
    int insertBatch(@Param("entities") List<Weather> entities);
}